package com.yearEndWorkload.pojo.excel.importTemplate;

import com.alibaba.excel.annotation.ExcelProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.math.RoundingMode;

@Data
public class PerformanceAppraisalExcel{

    /**
     * 年度
     */
    @ExcelProperty(value = "年份",index = 0)

    private String year;

    /**
     * 姓名
     */
    @ExcelProperty(value = "姓名",index = 1)
    private String teacherName;

    /**
     * 考核月份数
     */
    @ExcelProperty(value = "考核月份数",index = 2)
    private Integer assessMonths;

    /**
     * 金额
     */
    @ExcelProperty(value = "金额",index = 3)
    private BigDecimal amount;

    /**
     * 录入人
     */
    @ExcelProperty(value = "录入人",index = 4)
    private String reporter;

    // 方法来获取格式化的金额
    public BigDecimal getFormattedAmount() {
        return amount.setScale(2, RoundingMode.HALF_UP);
    }
}
